home *** CD-ROM | disk | FTP | other *** search
/ ShareWare OnLine 2 / ShareWare OnLine Volume 2 (CMS Software)(1993).iso / games2 / twast11.zip / TWASTMAC.ZIP / TWASSIST.SLT < prev   
Text File  |  1993-02-06  |  4KB  |  113 lines

  1. //  twassist.slt  (Telix script to display the information that can be
  2. //                 used by TWASSIST)
  3. //
  4. //  10/10/92 - D. Roseen - v1.0
  5. //
  6. //  10/31/92 - D. Roseen - v1.1 to do the following:
  7. //                          - Move the View Game Status so it's first.
  8. //                          - Move avoid list so it's last.
  9. //
  10. //  02/05/93 - D. Roseen - v1.2 to do the following:
  11. //                          - Fixed avoid problem where it wouldn't return
  12. //                            to main command prompt if avoids were set.
  13. //                          - Added menu.
  14. //                          - Added running TWASSIST, CIM port, CIM 
  15. //                            warp/port, and fighter/mines/avoids options.
  16.  
  17. main()
  18.  
  19. {
  20.   str key[2];
  21.   str datadir[] = "d:\twassist";   // YOUR TWASSIST DIRECTORY
  22.  
  23.   while (1)
  24.     {
  25.     box(20, 5, 52, 18, 3, 0, 7);
  26.     pstraxy(" 02/05/93 - D. Roseen - v1.2 ", 22, 5, 10);
  27.     pstraxy("( )W2002 Assistant", 22, 7, 7);
  28.     pstraxy("T", 23, 7, 11);
  29.     pstraxy("( )ll reports", 22, 9, 7);
  30.     pstraxy("A", 23, 9, 11);
  31.     pstraxy("( )IM warp and port reports", 22, 10, 7);
  32.     pstraxy("C", 23, 10, 11);
  33.     pstraxy("( )ort report", 22, 11, 7);
  34.     pstraxy("P", 23, 11, 11);
  35.     pstraxy("( )ighters, mines, and avoids", 22, 12, 7);
  36.     pstraxy("F", 23, 12, 11);
  37.     pstraxy("E( )it script", 22, 14, 7);
  38.     pstraxy("x", 24, 14, 11);
  39.     pstraxy("Your selection? ", 22, 16, 7);
  40.     getsxy(key, 1, 38, 16, 14);
  41.  
  42.     if (!(strcmpi(key, "T")))
  43.       {
  44.       newdir(datadir);             // STRING VAR. DEFINED AT TOP OF SCRIPT
  45.       run("twassist", "", 1);
  46.       clear_scr();
  47.       cputs("^M^M");
  48.       break;
  49.       }
  50.     else if (!(strcmpi(key, "A")))
  51.       {
  52.       clear_scr();
  53.       cputs ("V");                 // VIEW GAME STATUS
  54.                                    // WAIT FOR COMMAND PROMPT OR 20 SECONDS
  55.       waitfor("] (?=Help)?", 30);
  56.       cputs ("G");                 // SHOW DEPLOYED FIGHTERS
  57.       cputs ("K");                 // SHOW DEPLOYED MINES
  58.       cputs ("C");                 // ENGAGE CRAI XXV ONBOARD COMPUTER
  59.       cputs ("X");                 // LIST CURRENT AVOIDS
  60.       waitfor("Computer command", 30);
  61.       cputs ("╚╔╩╦╠═");            // COMPUTER INTERROGATION MODE (CIM)
  62.       cputs ("I");                 // INTER SECTOR WARP REPORT
  63.       waitfor(":", 200);
  64.       cputs ("R");                 // PORT REPORT
  65.       cputs ("Q");                 // QUIT CIM
  66.       waitfor("Computer command", 200);
  67.       cputs ("Q");                 // EXIT COMPUTER
  68.       break;
  69.       }
  70.     else if (!(strcmpi(key, "C")))
  71.       {
  72.       clear_scr();
  73.       cputs ("C");                 // ENGAGE CRAI XXV ONBOARD COMPUTER
  74.       cputs ("╚╔╩╦╠═");            // COMPUTER INTERROGATION MODE (CIM)
  75.       cputs ("I");                 // INTER SECTOR WARP REPORT
  76.       cputs ("R");                 // PORT REPORT
  77.       waitfor(":", 200);
  78.       cputs ("Q");                 // QUIT CIM
  79.       waitfor("Computer command", 200);
  80.       cputs ("Q");                 // EXIT COMPUTER
  81.       break;
  82.       }
  83.     else if (!(strcmpi(key, "P")))
  84.       {
  85.       clear_scr();
  86.       cputs ("C");                 // ENGAGE CRAI XXV ONBOARD COMPUTER
  87.       cputs ("╚╔╩╦╠═");            // COMPUTER INTERROGATION MODE (CIM)
  88.       cputs ("R");                 // PORT REPORT
  89.       cputs ("Q");                 // QUIT CIM
  90.       waitfor("Computer command", 200);
  91.       cputs ("Q");                 // EXIT COMPUTER
  92.       break;
  93.       }
  94.     else if (!(strcmpi(key, "F")))
  95.       {
  96.       clear_scr();
  97.       cputs ("G");                 // SHOW DEPLOYED FIGHTERS
  98.       cputs ("K");                 // SHOW DEPLOYED MINES
  99.       cputs ("C");                 // ENGAGE CRAI XXV ONBOARD COMPUTER
  100.       cputs ("X");                 // LIST CURRENT AVOIDS
  101.       waitfor("Computer command", 30);
  102.       cputs ("Q");                 // EXIT COMPUTER
  103.       break;
  104.       }
  105.     else if (!(strcmpi(key, "x")))
  106.       {
  107.       clear_scr();
  108.       cputs("^M^M");
  109.       break;
  110.       }
  111.     }
  112. }
  113.